BEGIN {
   Color1="brown"
   Color2="teal"  
   Color3="gray"
   Words = "function gsub sub gensub "      \
        " for in int if else while print printf" \
        " sprintf rand switch"                    \
        " BEGIN END next continue  "               \
        " return length "
    split(Words,Tmp," ")
    for(Word in Tmp) {
        Pat = Pat Sep "\\y" Tmp[Word] "\\y"
        Sep = "|"
    }
    Pat = "(" Pat ")"
}
/^<\/pre>/ { In = 0 }
/^<pre>/   { In = 1 }
In { gsub(Pat,      "<b><font color="Color1">&</font></b>") 
     gsub(/"[^"]*"/,"<b><font color="Color2">&</font></b>")
     gsub(/##.*/,   "<b><font color="Color3">&</font></b>")
     gsub(/[{}]/,   "<b>&</b>") 
   }
   { print $0 }
